package domd;
class student {
   private String name;
   private int age;
private  static String school="A大学";

    public student(String name, int age) {
        this.name = name;
        this.age = age;
    }
    public void infp(){
        System.out.println("姓名" + this.name + ",年龄：" + this.age + ",学校：" + school);
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public static String getSchool() {
        return school;
    }

    public static void setSchool(String school) {
        student.school = school;
    }
}
public class Main {
    public static void main(String[] args) {
        student student1=new student("张三",18);
        student student2=new student("张er",19);
        student1.setSchool("B大学");
        student1.infp();
        student2.infp();
    }
}
